begin tran
declare @upd_id int
select @upd_id = convert(int, var_data) from igs_parm with(updlock) where var_name = 'gv_upd_id'

update pos_st_ctrl set qty = 1 , upd_id = @upd_id
where sku = '6952051823760' and shop_code ='zsko'  and 
		org_in_note = 'KO-SI02158'
update  pos_bin_stock set qty = 1 , upd_id = @upd_id  where sku = '6952051823760' and shop_code ='zsko'

update pos_st_ctrl set qty = 2  , upd_id = @upd_id
where sku = '6952051826990' and shop_code ='zsko'  and 
		org_in_note = 'KO-SI01885' and org_in_seq = 49
update  pos_bin_stock set qty = 2 , upd_id = @upd_id  where sku = '6952051826990' and shop_code ='zsko'

update pos_st_ctrl set qty = 0 , upd_id = @upd_id
where sku = '6952051833431' and shop_code ='zsko' 
update  pos_bin_stock set qty = 0 , upd_id = @upd_id  where sku = '6952051833431' and shop_code ='zsko'

update pos_st_ctrl set qty = 1 , upd_id = @upd_id 
where sku = '6952051835329' and shop_code ='zsko'  and 
		org_in_note = 'KO-SI02243' and dc_pick_no = 'KO-IS0009058'
update  pos_bin_stock set qty = 1 , upd_id = @upd_id  where sku = '6952051835329' and shop_code ='zsko'

 update pos_st_daily_bal set adj_qty = 0, end_dp_qty = 0  
where sku = '6952051833431' and shop_code ='zsko' and trx_date between  '2011.04.01' and '2012.05.30' and end_dp_qty < 0

commit  tran